package cn.ad.server.domain;

import java.io.Serializable;
import java.util.Date;

public class SysConfig implements Serializable {
	
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 2744058605938883552L;
	static final String VERSION = "0";
	public static final String CACHE_NAME = "config";
	
	private int id;
	private String configKey;
	private String configValue;
	private Date createTime;
	private Date updateTime;
	private int status;
	/**
	 * 描述
	 */
	private String descr;
	
	public static String cacheKey(long id) {
		return new StringBuffer(CACHE_NAME).append(":").append(VERSION).append(":").append(id).toString();
	}
	
	public String toCacheKey() {
		return new StringBuffer(CACHE_NAME).append(":").append(VERSION).append(":").append(this.getId()).toString();
	}

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public String getConfigKey() {
		return configKey;
	}

	public void setConfigKey(String configKey) {
		this.configKey = configKey;
	}

	public String getConfigValue() {
		return configValue;
	}

	public void setConfigValue(String configValue) {
		this.configValue = configValue;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

	public String getDescr() {
		return descr;
	}

	public void setDescr(String descr) {
		this.descr = descr;
	}
}
